
[<tag id="selecteditemid" type="postback" value="" />]

<script>

$(document).ready(function() {

	$(".selectmove").hide();
	$(".selectcancel").hide();		
	$(".savebutton").hide();

    $(".selectrecord").click(function() {
		$(".selectrecord").hide();
		$(".selectmove").show();
		$(".selectmove[[itemid='" + $(this).attr("itemid") + "']]").hide();
		$(".selectcancel[[itemid='" + $(this).attr("itemid") + "']]").show();
		$("input[[id*='selecteditemid']]").val($(this).attr("itemid"));

		var selectid = $(this).attr("itemid");
		$(".selectmove").each(function (index) {
		    if ($(this).attr("parentlist").indexOf(selectid + ";") > -1) $(this).hide();
        });


    });

    $(".selectcancel").click(function() {
		$(".selectmove").hide();
		$(".selectcancel").hide();		
		$(".selectrecord").show();		
		$("input[[id*='selecteditemid']]").val('');
    });

    $("input[[id*='txtcategoryname']]").keyup(function() {
		var id = $(this).attr("id").replace('txtcategoryname','isdirty');
		$('#' + id).val(true);
		$(".savebutton").show();
    });
    $("input[[id*='chkishidden']]").change(function () {
        var id = $(this).attr("id").replace('chkishidden', 'isdirty');
        $('#' + id).val(true);
        $(".savebutton").show();
    });
    $("select[[id*='ddlparentcatid']]").change(function () {
        var id = $(this).attr("id").replace('ddlparentcatid', 'isdirty');
        $('#' + id).val(true);
        $(".savebutton").show();
    });

});

</script>

<br />

<div id="pageactionssource"><!-- Page actions are moved into header bar - also exist at page bottom-->
	<div class="col-xs-9 col-sm-9">
		<a href="#" class="show-sidebar">
		  <i class="fa fa-bars"></i>
		</a>
		<div class="actionbuttonwrapper">
		[<tag id="cmdAdd" type="linkbutton" resourcekey="General.cmdAddButton" cssclass="btn btn-primary" commandname="addnew"/>]
	    [<tag id="cmdSave" type="linkbutton" resourcekey="General.cmdSaveButton" cssclass="savebutton btn btn-warning" commandname="saveall"/>]
	    </div>
	</div>
	<div class="col-xs-3 col-sm-3 top-panel-right">
		[<tag type="selectlocalebutton" size="32"/>]
	</div>
</div>

<div class="row">
	
<div class="categorybreadcrumbs">[<tag type="catbreadcrumb" links="True" separator="" aslist="true" />]</div>

<div class="col-xs-12 col-sm-12">
		<div class="box">
			<div class="box-header">
				<div class="box-name">
					<i class="fa fa-table"></i>
					<span>[<tag type="valueof" resourcekey="General.Categories" />]</span>
				</div>
				<div class="box-icons">
					<a class="collapse-link">
						<i class="fa fa-chevron-up"></i>
					</a>
					<a class="expand-link">
						<i class="fa fa-expand"></i>
					</a>
					<a class="close-link">
						<i class="fa fa-times"></i>
					</a>
				</div>
				<div class="no-move"></div>
			</div>
<div class="box-content">
            [<tag id="cmdClose" type="linkbutton" resourcekey="General.cmdReturnIcon" commandname="close" />]
						<table class="table table-striped table-hover categorylist">
							<thead>
								<tr>
									<th></th>
									<th>[<tag type="valueof" resourcekey="General.Products" />]</th>
									<th>[<tag type="valueof" resourcekey="General.Name" />][<tag type="editflag" />]</th>
									<th> </th>
									<th> </th>
									<th> </th>
									<th>[<tag type="valueof" resourcekey="General.Hidden" />]</th>
								</tr>
							</thead>
							<tbody>
